pidofproc(): Make sure to try /bin/pidof when no pidfile is specified.
Move the pidof-using block inside the conditional to have it run when we know
that the pidfile doesn't exist but before assuming that the program was indeed
using one.
Closes: #668958 Reported-by: Adrian Fita <adrian.fita@gmail.com> Signed-off-by: Didier Raboud <odyx@debian.org>
Didier Raboud [Fri, 30 Mar 2012 12:48:42 +0000 (14:48 +0200)]
Make the init.d scripts messages fancier by prepending them a [....] block.
== Implementation ==
* The logging functions assign the status block as "[....]" when
printing the log message.
Concerned functions:
- log_daemon_msg
- log_action_begin_msg
- log_begin_msg (despite not being a documented interface)
* The log message conclusion functions replace the status block by
either a green [ ok ], a yellow [warn] or a red [FAIL] by
Concerned functions:
- log_end_msg
This is implemented as _pre/_post functions.
== Documentation ==
* lsb-base.README.Debian is updated with the new _pre/_post functions.
* lsb-base.NEWS gets a new entry with information meant for experimental
users and init.d scripts maintainers.
Didier Raboud [Wed, 7 Mar 2012 12:26:01 +0000 (13:26 +0100)]
In killproc(), re-add a '--retry 5' to s-s-d when no signal is specified.
According to the letter of the LSB:
killproc:"If a signal is specified, (...) the program is sent that signal.
Otherwise, a SIGTERM followed by a SIGKILL after an unspecified
number of seconds shall be sent."
According to start-stop-daemon manpage, that's what `--retry 5` does, with `5
seconds` being the `unspecified` of LSB, hence the `--retry 5` is only added
in the case where no signal is specified.
Closes: #650584 Reported-by: Daniel Nelson <torham@connect2.com> Signed-off-by: Didier Raboud <odyx@debian.org>
Didier Raboud [Sun, 11 Mar 2012 13:59:18 +0000 (14:59 +0100)]
Fix both unused and undeclared local variables in pidofproc.
This fixes:
- one bug introduced by the fix for #327405 in 3.0-6, which stopped using the
`line` variable;
- one bug introduced in 3.2-20, which started to use the `base` variable
without declaring it in local.
Closes: #663351 Reported-by: Liu Yubao <yubao.liu@gmail.com> Signed-off-by: Didier Raboud <odyx@debian.org>
Didier Raboud [Tue, 6 Mar 2012 12:45:31 +0000 (13:45 +0100)]
Promote lsb-release to Priority: optional.
Currently, 15 packages of priority "optional" depend on lsb-release and this
promotion fixes the override disparity between the archive and the package.
Didier Raboud [Sun, 19 Feb 2012 15:31:56 +0000 (16:31 +0100)]
Upgrade to support LSB 4.1.
LSB changes:
- Bump Depends:
- on libglib2.0-0 to >= 2.12.13;
- on fontconfig to >= 2.6.0;
- on libglib2.0-0 to >= 2.12.13;
- on libatk1.0-0 to >= 1.10.3;
- on libpango1.0-0 to >= 1.10.4;
- on libgtk2.0-0 to >= 2.10.14;
- Add Depends:
- on libglu1;
- on libcairo2 to >= 1.2.0;
- on libxtst6;
- on ghostscript-cups;
- In lsb, bump lsb-printing from Suggests to Depends.
- Add the lsb-security package.
- Drop the now-obsolete lsb-qt4 package.
Debian changes:
- libgl1-mesa-glx is the first alternative for libgl1;
- Make sure all packages have ${misc:Depends}.
Till Kamppeter [Sun, 19 Feb 2012 14:52:06 +0000 (15:52 +0100)]
Add the "lsb-invalid-mta" package, with a fake sendmail.
This allows the installation of LSB packages to not pull in an MTA any more,
which once adds awkward configuration questions to the installation process
and second adds an often unnneeded daemon to the system.
Didier Raboud [Mon, 27 Feb 2012 13:53:50 +0000 (14:53 +0100)]
Recognise Debian Ports as `sid` too.
This extends the interface of guess_release_from_apt to accept new
origin-label pairs, with a default to accept 'Debian Ports':
'ftp.debian-ports.org'. It also special-cases Debian Ports when guessing
Release and Codename.
Simone Rossetto [Tue, 21 Feb 2012 13:08:45 +0000 (14:08 +0100)]
Fix for unsupported negative value in pin priorities.
The priorities of repositories can be negative as reported in apt_preferences
manpage "P < 0 prevents the version from being installed". The lsb_release.py
script matches only positive values generating an invalid output for negative
priorities.
Steve Langasek [Tue, 21 Feb 2012 15:49:04 +0000 (16:49 +0100)]
Don't run apt-cache if /etc/lsb-release exists.
Since /etc/lsb-release overrides detected information, there's no
need to try and detect that information if lsb-release contains
everything we need. This saves us calling the hugely expensive
apt-cache.
Michael Vogt [Fri, 17 Feb 2012 10:12:01 +0000 (11:12 +0100)]
Switch from python-central to dh_python2.
(This was initially done in the 4.0-0ubuntu12 upload but is now done slightly
differently.)
Note that 2.6.6-6~ is needed (instead of 2.6.6-3~) because of
"- create symlinks for files installed into /usr/share/pyshared/ if there
are no other public modules available"